<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/html"><head>
    <meta charset="utf-8">
    <title>{include file="common/title"}</title>

    <meta name="description" content="Dashboard">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <!--Basic Styles-->
    <link href="__DATA__/admin/style/bootstrap.css" rel="stylesheet">
    <link href="__DATA__/admin/style/font-awesome.css" rel="stylesheet">
    <link href="__DATA__/admin/style/weather-icons.css" rel="stylesheet">

    <!--Beyond styles-->
    <link id="beyond-link" href="__DATA__/admin/style/beyond.css" rel="stylesheet" type="text/css">
    <link href="__DATA__/admin/style/demo.css" rel="stylesheet">
    <link href="__DATA__/admin/style/typicons.css" rel="stylesheet">
    <link href="__DATA__/admin/style/animate.css" rel="stylesheet">
</head>
<body>
<!-- 头部 -->
{include file="common/top"}
<!-- /头部 -->

<div class="main-container container-fluid">
    <div class="page-container">
        <!-- Page Sidebar -->
        {include file="common/left"}
        <!-- /Page Sidebar -->
        <!-- Page Content -->
        <div class="page-content">
            <!-- Page Breadcrumb -->
            <div class="page-breadcrumbs">
                <ul class="breadcrumb">
                    <li class="active">控制面板</li>
                </ul>
            </div>
            <!-- /Page Breadcrumb -->

            <!-- Page Body -->
            <!--正文-->
            <!--<form action="" method="post">-->
            <!--<div class="input-group col-md-3" style="margin-top:10px;margin-left: 20px;">-->
            <!--<input type="text" class="form-control" name="search" placeholder="请输入分配名称" />-->
            <!--<span class="input-group-btn">-->
            <!--<button class="btn btn-info btn-search">搜索</button>-->
            <!--&lt;!&ndash;<button class="btn btn-info btn-search" style="margin-left:3px">添加</button>&ndash;&gt;-->
            <!--</span>-->
            <!--</div>-->
            <!--</form>-->
            <div class="page-body">
                <button type="button" tooltip="添加优惠券" class="btn btn-sm btn-azure btn-addon" onClick="javascript:window.location.href = '{:url('business/lessen/create')}'"> <i class="fa fa-plus"></i> 添加优惠券
                </button>
                <div class="row">
                    <div class="col-lg-12 col-sm-12 col-xs-12">
                        <div class="widget">
                            <div class="widget-body">
                                <div class="flip-scroll">
                                    <table class="table table-bordered table-hover">
                                        <thead class="">
                                        <tr>
                                            <th class="text-center">优惠券名称</th>
                                            <th class="text-center">到期时间</th>
                                            <th class="text-center">满多少可用</th>
                                            <th class="text-center">减免多少</th>
                                            <th class="text-center">每人限领数量</th>
                                            <th class="text-center">库存量</th>
                                            <th class="text-center">操作</th>
                                        </tr>
                                        </thead>
                                        <tbody>
                                        {volist name="$data" id="v"}
                                        <tr>
                                            <td align="center">{$v.lessen_name}</td>
                                            <td align="center"><?php echo date("Y-m-d ",$v['lessen_date']) ?></td>
                                            <td align="center">{$v.lessen_full}</td>
                                            <td align="center">{$v.lessen_reduce}</td>
                                            <td align="center">{$v.lessen_chance}</td>
                                            <td align="center">{$v.lessen_count}</td>
                                            <td align="center">
                                                <a href="#" onClick="warning('确实要删除吗', '{:url('business/lessen/delete',array('id' => $v['id']))}')" class="btn btn-default btn-sm shiny">
                                                    <i class="fa fa-edit"></i> 删除优惠券
                                                </a>
                                                <a href="{:url('business/lessen/edit',array('id' => $v['id']))}"  class="btn btn-success btn-sm shiny">
                                                    <i class="fa fa-edit"></i> 编辑优惠券
                                                </a>
                                            </td>
                                        </tr>
                                        {/volist}
                                        <!-- Modal -->
                                        </tbody>
                                    </table>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            <!--Basic Scripts-->
            <script src="__DATA__/admin/style/jquery_002.js"></script>
            <script src="__DATA__/admin/style/bootstrap.js"></script>
            <script src="__DATA__/admin/style/jquery.js"></script>
            <!--Beyond Scripts-->
            <script src="__DATA__/admin/style/beyond.js"></script>

            <script>
                $(function(){
                    $('.youhuiquan').css('display','block');
                });
            </script>
</body></html>